package com.woniuxy.goods.manaer.feigns;

import com.woniuxy.goods.module.user.User;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

//@FeignClient(value = "goods-login-server",fallback = UserFeignClientFallback.class)
@FeignClient(value = "goods-login-server")
public interface UserFeignClient {
    @PostMapping("/user/login")
    User loginApi(@RequestBody User user);

    @GetMapping("/user/findUserByKey/{id}")
    User findUserByKey(@PathVariable("id") int id);
}
